<template>
  <!-- 用户中心 -->
  <div class="userCenter">
    <!-- 定义顶部导航栏 -->
    <user-center-top />
    <!-- 定义用户详情 -->
    <user-center-banner />
    <!-- 定义天气内容 -->
    <user-center-content />
    <!-- 定义页脚 -->
    <user-center-footer class="d-none d-md-block" />
    <!-- 定义移动端脚页 -->
    <div class="d-block d-md-none">
      <footer-text-s-m />
      <mobile-banner /> 
    </div>
  </div>
</template>

<script>
  import UserCenterTop from './UserCenterComponents/UserCenterTop'
  import UserCenterBanner from './UserCenterComponents/UserCenterBanner'
  import UserCenterContent from './UserCenterComponents/UserCenterContent'
  import UserCenterFooter from './UserCenterComponents/UserCenterFooter'
  import FooterTextSM from 'components/FooterText/FooterTextSM'
  import MobileBanner from 'components/Mobile/MobileBanner'

  export default {
    name: 'UserCenter',
    components: {
      UserCenterTop,
      UserCenterBanner,
      UserCenterContent,
      UserCenterFooter,
      FooterTextSM,
      MobileBanner
    },
    data () {
      return {

      }
    },
    // 在组件渲染前更改是否刷新书籍页的判断值
    beforeRouteEnter(to, from, next) {
      localStorage.setItem('bannerFlag', true);
      next();
    }
  }

</script>

<style>
  body {
    background-color: rgb(240,240,240);
  }
</style>